home *** CD-ROM | disk | FTP | other *** search
/ Interactive Media Design Review 1999 / Interactive Media Design Review 1999.iso / mac / files / IDSTART.DIR / 00007.ls < prev    next >
Encoding:
Text File  |  1999-04-29  |  2.2 KB  |  98 lines

  1. global qtproblem, discproblem, oldticks, Started, oldcolor, notquitting, lowram, CDPath, IDSoundVolume, IDCDPath, bgmusic, demofolder
  2.  
  3. on startMovie
  4.   clearGlobals()
  5. end
  6.  
  7. on exitFrame
  8.   go(the frame)
  9. end
  10.  
  11. on Mac
  12.   return the machineType <> 256
  13. end
  14.  
  15. on checkforproblems
  16.   the itemDelimiter = ","
  17.   qtproblem = "QT"
  18.   discproblem = 0
  19.   if not (the quickTimePresent) then
  20.     qtproblem = 1
  21.   end if
  22.   if Mac() then
  23.     CDName = field("Mac CD Name")
  24.     it = CDName & ":ID99CHK:"
  25.     it = getNthFileNameInFolder(it, 1)
  26.     if it = EMPTY then
  27.       discproblem = 1
  28.     else
  29.       the searchPaths = [CDName, CDName & ":ALLFILES"]
  30.       IDCDPath = CDName & ":"
  31.     end if
  32.   else
  33.     here = the moviePath & "ID99CHK\"
  34.     if getNthFileNameInFolder(here, 1) <> EMPTY then
  35.       IDCDPath = the moviePath
  36.     else
  37.       if voidp(CDPath) then
  38.         CDPath = EMPTY
  39.       end if
  40.       theletters = char 1 of CDPath & "defghijklmnopqrstuvwxyz!"
  41.       repeat with a = 1 to the number of chars in theletters
  42.         driveletter = char a of theletters
  43.         if driveletter = "!" then
  44.           exit repeat
  45.         end if
  46.         it = driveletter & ":\ID99CHK\"
  47.         it = getNthFileNameInFolder(it, 1)
  48.         if it <> EMPTY then
  49.           exit repeat
  50.         end if
  51.       end repeat
  52.       if driveletter = "!" then
  53.         discproblem = 1
  54.       else
  55.         lowram = EMPTY
  56.         the searchPaths = [driveletter & ":\ALLFILES\"]
  57.         IDCDPath = driveletter & ":\"
  58.       end if
  59.     end if
  60.   end if
  61.   if (qtproblem = 1) or (discproblem = 1) then
  62.     if Mac() then
  63.       go("quit mac")
  64.     else
  65.       go("quit pc")
  66.     end if
  67.     exit
  68.   else
  69.     oldticks = the ticks
  70.     Started = 1
  71.     oldcolor = the colorDepth
  72.     if the colorDepth < 16 then
  73.       set the colorDepth to 16
  74.     end if
  75.     if the colorDepth < 16 then
  76.       set the colorDepth to 32
  77.     end if
  78.   end if
  79. end
  80.  
  81. on keyDown
  82.   wasnumber = 0
  83.   if "0123456789" contains the key then
  84.     wasnumber = 1
  85.     k = integer(the key)
  86.     IDSoundVolume = (k * k * 3) + 5
  87.     if the volume of sound 1 > 0 then
  88.       set the volume of sound 1 to IDSoundVolume
  89.     end if
  90.     if the volume of sound 2 > 0 then
  91.       set the volume of sound 2 to IDSoundVolume
  92.     end if
  93.   end if
  94.   if not wasnumber then
  95.     pass()
  96.   end if
  97. end
  98.